<template>
  <router-view />
</template>

<script setup>
import useSettingsStore from '@/store/modules/settings'
import { handleThemeStyle } from '@/utils/theme'

onMounted(() => {
  document.documentElement.style.setProperty('--el-color-image-preview-primary', useSettingsStore().theme)

  nextTick(() => {
    // 初始化主题样式
    handleThemeStyle(useSettingsStore().theme)
  })
})
</script>

<style lang="scss">
// 去掉全局样式替换
  //.el-form-item {
  //  margin-bottom: 4px !important;
  //}
  //
  //.el-form--inline .el-form-item {
  //  margin-right: 0px;
  //}

  .el-image-viewer__close {
    background-color: var(--el-color-image-preview-primary) !important;
  }
  .el-image-viewer__prev {
    background-color: var(--el-color-image-preview-primary) !important;
  }
  .el-image-viewer__next {
    background-color: var(--el-color-image-preview-primary) !important;
  }
</style>